#pragma warning disable 108
using System;
using System.Runtime.InteropServices;
using System.Collections.Generic;
using Cephei;
using Cephei.Core;
using Cephei.Core.Generic;
using Microsoft.FSharp.Core;
using Cephei.QL;
namespace Cephei.QL.Instruments
{
    /// <summary> 
	/// ! The cash flows belonging to the first leg are paid; the ones belonging to the second leg are received.  \ingroup instruments
	/// </summary>
    [Guid ("B8478B8D-F621-49cb-A77C-88755CBF5B8B"),ComVisible(true)]
	public interface ISwap : Cephei.QL.IInstrument
	{
		///////////////////////////////////////////////////////////////
        // Methods
        //
        /// <summary> 
		/// 
		/// </summary>
		 Boolean IsExpired {get;}
        /// <summary> 
		/// 
		/// </summary>
		 Cephei.Core.IVector<Cephei.QL.ICashFlow> Leg(UInt64 j);
        /// <summary> 
		/// 
		/// </summary>
		 Double LegBPS(UInt64 j);
        /// <summary> 
		/// 
		/// </summary>
		 Double LegNPV(UInt64 j);
        /// <summary> 
		/// 
		/// </summary>
		 DateTime MaturityDate {get;}
        /// <summary> 
		/// 
		/// </summary>
		 DateTime StartDate {get;}
        /// <summary> 
		/// 
		/// </summary>
		 Double EndDiscounts(UInt64 j);
        /// <summary> 
		/// 
		/// </summary>
		 Double NpvDateDiscount {get;}
        /// <summary> 
		/// 
		/// </summary>
		 Double StartDiscounts(UInt64 j);
    }   

    /// <summary> 
	/// ! The cash flows belonging to the first leg are paid; the ones belonging to the second leg are received.  \ingroup instruments Factory
	/// </summary>
   	[ComVisible(true)]
    public interface ISwap_Factory 
    {
        ///////////////////////////////////////////////////////////////
        // Factory methods
        //
        /// <summary> 
		/// 
		/// </summary>
	    ISwap Create (Cephei.Core.IMatrix<Cephei.QL.ICashFlow> legs, Cephei.Core.IVector<Boolean> payer, Cephei.QL.IPricingEngine QL_Pricer);
        /// <summary> 
		/// 
		/// </summary>
	    ISwap Create (Cephei.Core.IVector<Cephei.QL.ICashFlow> firstLeg, Cephei.Core.IVector<Cephei.QL.ICashFlow> secondLeg, Cephei.QL.IPricingEngine QL_Pricer);
    }
}

